<?php

namespace adminmatrix\server\command\make;
use think\console\command\Make;
class MakeLogic extends Make
{
    protected $type = "Logic";

    protected function configure()
    {
        parent::configure();
        $this->setName('make:logic')
            ->setDescription('创建Logic逻辑类');
    }

    protected function getStub(): string
    {
        $stubPath = __DIR__. DIRECTORY_SEPARATOR.'stubs'. DIRECTORY_SEPARATOR;

        return $stubPath. 'logic.stub';
    }

    protected function getClassName(string $name) : string
    {
        return parent::getClassName($name) .  'Logic' ;
    }

    protected function getNamespace(string $app): string
    {
        return parent::getNamespace($app). '\\logic';
    }
}